package com.SoftwareEngineering.service;
import com.SoftwareEngineering.dao.UserMapper;
import com.SoftwareEngineering.pojo.User;
import org.springframework.transaction.annotation.Transactional;

import javax.inject.Inject;
import javax.inject.Named;

@Named
@Transactional
public class UserService {
    @Inject
    private UserMapper mapper;

    public User findUserByUserName(String name){
        return mapper.findUserByName(name);
    }
    public void saveUser(User user){
        mapper.saveUser(user);
    }
}
